#define _CRT_SECURE_NO_WARNINGS
#include "variable.h"
extern int a, b;
extern float Max1, Min1;
extern int A;
void test_7_14()
{
	float ave, score[10];
	int i;
	printf("Please enter 10 scores:");
	for (i = 0; i < 10; i++)
	{
		scanf("%f", &score[i]);
	}
	ave = average(score, 10);
	printf("max=%6.2f\nmin=%6.2f\nnaverage=%6.2f\n", Max1, Min1, ave);
}


void test_7_15()
{
	int a = 8;
	printf("max=%d\n", max(a, b));
}


void test_7_16()
{
	int a = 2, i;
	for (i = 0; i < 3; i++)
	{
		printf("%d\n", f(a));
	}
}


void test_7_17()
{
	int i;
	for (i = 1; i <= 5; i++)
	{
		printf("%d!=%d\n", i, fac(i));
	}
}


void test_7_18()
{
	extern A, B, C;
	printf("Please enter three integer numbers:");
	scanf("%d %d %d", &A, &B, &C);
	printf("max is %d\n", max1());
}


void test_7_19()
{
	int b = 3, c, d, m;
	printf("enter the number a and its power m:\n");
	scanf("%d %d", &A, &m);
	c = A * b;
	printf("%d * %d = %d\n", A, b, c);
	d = power(m);
	printf("%d * * %d = %d\n", A, m, d);
}


void test_7_20()
{
	extern void enter_string(char str[]);
	extern void delete_string(char str[], char ch);
	extern void print_string(char str[]);
	char ch, str[80];
	enter_string(str);
	scanf("%c", &ch);
	delete_string(str, ch);
	print_string(str);
}